package services;

import dao.IFurniture;
import factory.FurnitureDaofactory;
import vo.Furniture;

import java.util.List;

public class FurnitureServicempl implements IFurnitureService{
    IFurniture iFurniture= FurnitureDaofactory.getInstance();//获取具体操作类的对象
    @Override
    public boolean add(Furniture furniture) {
        return iFurniture.add(furniture);
    }

    @Override
    public boolean delete(Furniture furniture) {
        return iFurniture.delete(furniture);
    }

    @Override
    public boolean modify(Furniture furniture) {
        return iFurniture.modify(furniture);
    }

    @Override
    public Furniture getcustombyid(String id) {
        return iFurniture.getcustombyid(id);
    }

    @Override
    public List<Furniture> getall() {
        return iFurniture.getall();
    }
}
